<?php 
require_once __DIR__ . '/../autoload.php';
//引入用户信息检查类
use src\DataBase;
header('Content-Type: application/json');
$db= new DataBase\DataBaseOperate('139.196.124.180','school','user1','Mcx857264','utf8');
$newSelectMessage=$db->select('messageRelease','*',['isNew' => 1],'messageReleaseTime');
$result = ['code' => 0,'messageCount' => 0];
if($newSelectMessage)
{
    $result['messageCount'] = count($newSelectMessage);
}
die(json_encode($result,true));
?>